﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MoeRabbit
{
    class FileExistence
    {
        public bool FileExt(string FileName) {
            if (File.Exists(FileName))
                return true;
            else
                return false;
        }

        public bool DicExt(String DicName) {
            if (!Directory.Exists(DicName))
            {
                try
                {
                    Console.WriteLine("尝试创建");
                    Directory.CreateDirectory(DicName);
                }
                catch (Exception ex)
                {

                    Console.WriteLine(ex);
                }
                return true;
            }

            else
            {
                
                return false;
            }
        }
    }
}
